<% if active_scaffold_config.action_links.any? { |link| link.type == :table } -%>
  <% form_tag "/#{params[:controller]}/filter/", :id => "#{controller.controller_name}_filter-form", :method => :get do -%>
  <div class="actions">
    <% new_params = params_for(:action => :table) %>
    <% active_scaffold_config.action_links.each :table do |link| -%>
      <% next if controller.respond_to? link.security_method and !controller.send(link.security_method) -%>
      <%= render_action_link(link, new_params) -%>
    <% end -%>

    <% unless active_scaffold_config.list.filters.empty? %>
      <%= select_tag "name",
        options_for_select(active_scaffold_config.list.filters.collect {|f| [f.label, f.name]}, cookies["#{controller.controller_name}_filter"] ), 
        :onchange => "$('#{controller.controller_name}_filter-form').submit();",
        :style => "float:right;font-size: 95%" %>
      <%= image_tag 'active_scaffold_ext/filter', 
        :style => "padding:0px 3px;float:right;font-size: 95%" %>
    <% end -%>

    <%= loading_indicator_tag(:action => :table) %>
  </div>
  <% end -%>
<% end %>
<h2><%= @page_title or active_scaffold_config.list.user.label %></h2>
